package com.huyn.baseframework.dynamicload.video.model;

import com.huyn.baseframework.model.BaseModel;

import java.util.List;

/**
 * Created by huyaonan on 16/3/23.
 */
public class GoodsModel extends BaseModel {

    public GoodsItem goodsVo;

    public int startSeconds=0;
    public int endSeconds=0;

    public List<GoodsPoint> timelineCircleRespVoList;
    public List<GoodsCoordinate> rectangleTrajectoryList;

    //手动新加的id
    public String rid="";

    public String getId() {
        if(goodsVo == null)
            return "";
        return goodsVo._id;
    }

    public String getName() {
        if(goodsVo == null)
            return "";
        return goodsVo.tlTitle;
    }

    public float getGoodsTagLeftTop_X() {
        if(rectangleTrajectoryList == null || rectangleTrajectoryList.size() <= 0)
            return 0;
        return rectangleTrajectoryList.get(0).pointxPercent;
    }

    public float getGoodsTagLeftTop_Y() {
        if(rectangleTrajectoryList == null || rectangleTrajectoryList.size() <= 0)
            return 0;
        return rectangleTrajectoryList.get(0).pointyPercent;
    }

    public String getGoodsShowPicUrl() {
        if(goodsVo == null)
            return "";

        return goodsVo.showPicUrl;
    }

    public String getBeforeDesc() {
        if(goodsVo == null)
            return "";

        return goodsVo.beforeDesc;
    }

    public String getAfterDesc() {
        if(goodsVo == null)
            return "";

        return goodsVo.afterDesc;
    }

}
